import { createParamDecorator, ExecutionContext } from '@nestjs/common';
import { HerinHandle } from '../types/type/request.type';

export const Herin = createParamDecorator(
  (data: unknown, ctx: ExecutionContext): HerinHandle => {
    const request = ctx.switchToHttp().getRequest();
    const herin: HerinHandle = request.herin;
    return herin;
  },
);
